using System.ComponentModel;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Web.Services;

namespace Rainbow.WS
{
	/// <summary>
	/// AutoUpdate Service.
	/// </summary>
	public class AutoUpdateService : WebService
	{
		public AutoUpdateService()
		{
			//CODEGEN: This call is required by the ASP.NET Web Services Designer
			InitializeComponent();
		}

		#region Component Designer generated code
		
		//Required by the Web Services Designer 
		private IContainer components = null;
				
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		private void InitializeComponent()
		{
		}

		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if(disposing && components != null)
			{
				components.Dispose();
			}
			base.Dispose(disposing);		
		}
		
		#endregion

		//-----------------------------------------------------------------------------------------
//		[WebMethod]
//		public DataSet SelectNewsBySystem(string system_ID)
//		{
//			string connectionString = ConfigurationSettings.AppSettings["AUConnectionString"];
//			string spName = "p_Update_News_SelectBySystem";
//			SqlParameter[] parameters = new SqlParameter[1];
//			parameters[0] = new SqlParameter("@System_ID", system_ID);
//			return SqlHelper.ExecuteDataset(connectionString, CommandType.StoredProcedure, spName, parameters);
//		}
//		//-----------------------------------------------------------------------------------------
//		[WebMethod]
//		public DataSet SelectNewestVersion(string system_ID)
//		{
//			string connectionString = ConfigurationSettings.AppSettings["AUConnectionString"];
//			string spName = "p_Update_Version_SelectNewestVersion";
//			SqlParameter[] parameters = new SqlParameter[1];
//			parameters[0] = new SqlParameter("@System_ID", system_ID);
//			return SqlHelper.ExecuteDataset(connectionString, CommandType.StoredProcedure, spName, parameters);
//		}		
//		//-----------------------------------------------------------------------------------------
//		[WebMethod]
//		public DataSet SelectFileByVersion(int version_ID)
//		{
//			string connectionString = ConfigurationSettings.AppSettings["AUConnectionString"];
//			string spName = "p_Update_File_SelectByVersion";
//			SqlParameter[] parameters = new SqlParameter[1];
//			parameters[0] = new SqlParameter("@Version_ID", version_ID);
//			return SqlHelper.ExecuteDataset(connectionString, CommandType.StoredProcedure, spName, parameters);
//		}		
		
	}
}
